package eu.best.sercheng.runner;

import java.net.URL;
import java.util.LinkedList;

import eu.best.sercheng.fetcher.Fetcher;
import eu.best.sercheng.frontier.Frontiere;
import eu.best.sercheng.model.dao.MainDao;
import eu.best.sercheng.model.dao.MainDaoImpl;

public class CrawlerRunner {
	
	public static void main(String[] args) {
		try {
			MainDao dao = new MainDaoImpl();
			LinkedList<String> linkedList = new LinkedList<String>();

			Frontiere frontier = new Frontiere(new URL("http://www.collab.net/developers/tools/"));
			
			
			Fetcher fetcher = new Fetcher(new URL("http://www.collab.net/developers/tools/"),frontier,dao);
			new Fetcher(new URL("http://www.robotstxt.org/"),frontier,dao).start();
			new Fetcher(new URL("http://192.168.243.80/riw/"),frontier,dao).start();
			fetcher.start();
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
	
}
